package cn.trasen.his.poc.std.api.emums;

import pro.shushi.pamirs.meta.annotation.Errors;
import pro.shushi.pamirs.meta.common.enmu.ExpBaseEnum;
import pro.shushi.pamirs.meta.common.enmu.IEnum;

/**
 * 费控管理据模块错误枚举
 */
@Errors(displayName = "POC示例标准版错误枚举")
public enum PocDemoExpEnum implements ExpBaseEnum, IEnum<Integer> {

    SYSTEM_ERROR(ERROR_TYPE.SYSTEM_ERROR, 1000000, "系统异常"),
    PARAMETER_ISNULL(ERROR_TYPE.BIZ_ERROR, 2006034, "参数错误"),
    TRIP_STATUS_HAS_PENDING(ERROR_TYPE.BIZ_ERROR, 2006035, "申请单已是提交状态，不能重复提交"),;
    ;

    public static final String DICTIONARY = "hr.simple.exceptions";

    private final ERROR_TYPE type;
    private final int code;
    private final String msg;

    PocDemoExpEnum(ERROR_TYPE type, int code, String msg) {
        this.type = type;
        this.code = code;
        this.msg = msg;
    }

    @Override
    public ERROR_TYPE type() {
        return type;
    }

    @Override
    public int code() {
        return code;
    }

    @Override
    public String msg() {
        return msg;
    }
}
